package com.xinhua.entity;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.fasterxml.jackson.annotation.JsonIgnore;

@Entity
@Table(name="t_surveycontent")
public class SurveyContent {
	private Integer id;
	private String content;
	
	private SurveyItem surveyItem;
	
	public SurveyContent() {
		// TODO Auto-generated constructor stub
	}
	
	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	
	@ManyToOne
	@JoinColumn(name="item_id")
	@JsonIgnore
	public SurveyItem getSurveyItem() {
		return surveyItem;
	}
	public void setSurveyItem(SurveyItem surveyItem) {
		this.surveyItem = surveyItem;
	}
	public String getContent() {
		return content;
	}
	public void setContent(String content) {
		this.content = content;
	}
}
